package com.newcapec.modules.pass.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.newcapec.common.utils.PageUtils;
import com.newcapec.common.utils.Query;
import com.newcapec.modules.pass.dao.PassRecordDao;
import com.newcapec.modules.pass.entity.PassRecordEntity;
import com.newcapec.modules.pass.service.PassRecordService;
import org.springframework.stereotype.Service;

import java.util.Map;


@Service("passRecordService")
public class PassRecordServiceImpl extends ServiceImpl<PassRecordDao, PassRecordEntity> implements PassRecordService {

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        IPage<PassRecordEntity> page = this.baseMapper.selectPageVo(
                new Query<PassRecordEntity>().getPage(params, "create_time", false), params
        );

        return new PageUtils(page);
    }
}